﻿using System;
using System.Collections.Generic;
using System.ServiceModel;
using Tierless.Framework.Data;
using Tierless.Framework.EntityTypes;
using Tierless.Framework.ServiceContracts;

namespace Tierless.Framework.Client
{
	public class AsyncEntityClient : ClientBase<IAsyncEntityService>, IAsyncEntityService
	{
		[System.Diagnostics.DebuggerStepThrough]
		public IAsyncResult BeginGet(Tierless.Framework.Data.EntityRequests lookupRequest, AsyncCallback callback, object state)
		{
			return base.Channel.BeginGet(lookupRequest, callback, state);
		}

		[System.Diagnostics.DebuggerStepThrough]
		public List<EntitySet> EndGet(IAsyncResult result)
		{
			return base.Channel.EndGet(result);
		}

		[System.Diagnostics.DebuggerStepThrough]
		public IAsyncResult BeginSave(List<EntitySet> entitySets, AsyncCallback callback, object state)
		{
			return base.Channel.BeginSave(entitySets, callback, state);
		}

		[System.Diagnostics.DebuggerStepThrough]
		public EntitySaveResult EndSave(IAsyncResult result)
		{
			return base.Channel.EndSave(result);
		}

		[System.Diagnostics.DebuggerStepThrough]
		public IAsyncResult BeginDescribe(string[] entityNames, AsyncCallback callback, object state)
		{
			return base.Channel.BeginDescribe(entityNames, callback, state);
		}

		[System.Diagnostics.DebuggerStepThrough]
		public EntityType[] EndDescribe(IAsyncResult result)
		{
			return base.Channel.EndDescribe(result);
		}
	}
}
